package edu.sctu.wulixia.month4and5.day20150519;

/**
 * Created by user05 on 2015/5/24.
 */
public class Teachers_Data {
    Teacher[] teachers = new Teacher[2];
    public Teacher[] isTeachers() {
        Teacher teacher1 = new Teacher();
        teacher1.name = "张三" ;
        teacher1.sex = "男";
        teacher1.position = "讲师";
        teacher1.number = 10010;
        teacher1.lesson = "C语言";
        Student[] student_arrey1 = new Student[6];
        for (int i = 0; i < student_arrey1.length; i++) {
            Student student = new Student();
            student.name = "李四" + i;
            student.score = 56 + i;
            student.number = 10010 + i;
            student.age = 16 + i;
            student.address = "南充";
            if (i % 2 != 0) {
                student.sex = "男";
            } else {
                student.sex = "女";
            }
            student_arrey1[i] = student;
        }
        teacher1.student = student_arrey1;
        System.out.println(teacher1);
        Teacher teacher2 = new Teacher();
        teacher2.name = "张琪";
        teacher2.sex = "女";
        teacher2.position = "教授";
        teacher2.number = 3333;
        teacher2.lesson = "数据结构";
        Student[] student_arrey2 = new Student[6];
        for (int i = 0; i < student_arrey2.length; i++) {
            Student student = new Student();
            student.name = "王五" + i;
            student.score = 55 + i;
            student.number = 20010 + i;
            student.age = 17 + i;
            student.address = "成都";
            if (i % 2 != 0) {
                student.sex = "男";
            } else {
                student.sex = "女";
            }
            student_arrey2[i] = student;
        }
        teacher2.student = student_arrey2;
        System.out.println(teacher1);

        this.teachers[0] = teacher1;
        this.teachers[1] = teacher2;
        return teachers;
    }
}
